// Decompiled on 周六 2月 22 19:31:49 CST 2025 with Zomboid Decompiler v0.1.3 using Vineflower.
package zombie.core.skinnedmodel.Texture;

import java.util.HashMap;
import zombie.core.textures.Texture;

public class TextureManager {
    public static TextureManager Instance = new TextureManager();
    public HashMap<String, Texture2D> Textures = new HashMap();

    public boolean AddTexture(String name) {
        Texture texture = Texture.getSharedTexture(name);
        if (texture == null) {
            return false;
        } else {
            this.Textures.put(name, new Texture2D(texture));
            return true;
        }
    }

    public void AddTexture(String name, Texture texture) {
        if (!this.Textures.containsKey(name)) {
            this.Textures.put(name, new Texture2D(texture));
        }
    }
}
